Release 10.1A: OpenEdge Development:
AppBuilder
AppBuilder information (adeuib/_uibinfo.p)
Use the
adeuib/_uibinfo.pprocedure to obtain information about the widgets and SmartObject instances in a design window:
Input parameters
The
adeuib/_uibinfo.pprocedure takes the following input parameters:pi_contextThe context ID of the widget, SmartObject instance, code section, or procedure to access. If unknown (
?), AppBuilder assumes the current procedure. The value ofpi_contextcan be the context ID for any of the following:
- An object. For example, you can obtain the context of a button,
Btn_OK, with the following code:
- A procedure. For example, you can obtain the context for the current procedure with the following code:
- A SmartObject instance. For example, you can obtain the context of a SmartObject instance with the following code:
- A code section. For example, you can obtain the context ID and contents of the
MAIN-CODE-BLOCKsection with the following code:
pc_nameA quoted character string that specifies the name of an object. This string has the following syntax:
In this syntax:
objectis the name of the widget or SmartObject instance.frame-nameis the name of its parent frame.window-nameis the name of its parent window.file-nameis the name of the parent procedure file.handleis either the widget-handle of a widget or the procedure handle for a SmartObject instance.If you omit the
FRAMEorWINDOWoption, the current window and current frame are assumed. If an object is unique in a window, you can refer to it as objectINWINDOWwindow-name.To refer to a window or frame, preface the object with the type. For example, to find frame
f:
To find window
w:
To find a procedure with the name
p.w:
The following special cases also apply:
?— Gets the current object (shown in the AppBuilder’s main window)FRAME ?— Gets the current frame.WINDOW ?— Gets the current window.PROCEDURE ?— Gets the current procedure.If you use the
HANDLEhandleto reference an object, the handle can be either aWIDGET-HANDLEof the object orPROCEDURE-HANDLEfor a SmartObject (converted to aSTRING).PALETTEobject— Object is the name directly following # in thecstfile.pc_requestA quoted character string that specifies what to request. Valid requests are:
“NAME”— Returns the name of the object.“ATTRIBUTES”— Returns a string with all of the attributes read from thecstfile.“PROCEDURE”— Returns theSTRING(pi_context)for the current procedure.“FILE-NAME”— Returns the name of the parent procedure file as last saved by AppBuilder; if not saved, returns“?”.“TEMPLATE”— ReturnsYESorNOdepending on whether the current object is a template.“TYPE”— Returns the type of object.“HANDLE”— Returns either the widget-handle of the object or theadm-object-handleof a SmartObject.“PROCEDURE-HANDLE”— Returns the procedure handle of a SmartObject.“CONTEXT”— Returns the context ID of the widget or SmartObject instance.“CONTAINScontains-phrase”— Returns all objects contained in the current context (of a type or with key toggle boxes set). By default, returns the context ID of the items that match the filter, but you can ask for the list of names. The asterisk (*) returns all objects.The syntax for
contains-phraseis as follows:
In this syntax,
object-listis a comma-separated list (with no spaces) of object types.“FRAMES”— Returns all frames (in a window). This is shorthand forCONTAINSFRAMERETURNNAME.“FIELDS”— Returnsdbfieldsin frame ordbfieldsin browse.“EXTERNAL-TABLES”— Returns the list of external tables for a procedure.“TABLES”— The tables used by the query of aFRAME,BROWSE, orQUERYobject.“4GL-QUERY”— The 4GL query for the query of aFRAME,BROWSE, orQUERYobject.“WBX-FILE-NAME”— The name of the.wrxin which to save run-time attributes for the OCXs in a procedure.“COMPILE-INTO-DIR”— The directory where the procedure file is compiled.“&FRAME-NAME [RETURN NAME]”— The context ID or name of theFRAME-NAME, or?.“&QUERY-NAME [RETURN NAME]”— The context ID or name ofQUERY-NAME, or?.“&BROWSE-NAME [RETURN NAME]”— The context ID or name ofBROWSE-NAME, or?.Other options
To return a comma-separated list of procedure names:
The following returns the same list but uses context IDs instead of names:
SECTIONS function
You can ask a procedure for the list of internal procedures and functions defined in AppBuilder. The list can return the names or context IDs of the procedure and function sections, which you can use in
adeuib/_accsect.pto get, modify, or delete the contents of code blocks:
If you do not specify either
RETURNCONTEXTorRETURNNAME, it returns the list in context ID order.To obtain a list of all internal procedures in a file by name, use the following:
To obtain all of the procedures and functions defined in a file, use the following:
This returns the list in context ID order.
HTML-FILE-NAME
Returns the HTML filename associated with an HTML mapping object procedure.
BROKERURL
Returns the broker URL set in Web preferences:
REMOTE
Returns
TRUEif the Remote File Management button in AppBuilder is set to’Remote’, otherwise returnsFALSE:
WEBBROWSER
Returns the Web browser set in Web preferences.
DATAOBJECT
Returns the SmartDataObject associated with the procedure:
DATAOBJECT-INCLUDE
Returns the name of the include file associated with the SmartDataObject of the procedure:
PALETTE-ITEM
For a given custom definition in a
.cstfile, returns the settings forATTRIBUTES,LABEL,TEMPLATE, andFILES:
Output parameter
The
adeuib/_uibinfo.pprocedure uses the following output parameter:pc_infoOutput value, cast as a character string.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |